﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using web.data.entities;
using web.bussines;
using Webdiyer.WebControls.Mvc;
using System.Web.UI;
using web.core.Controllers;

namespace web.core.Models
{
    public class emailTemplateModels
    {
        //get all get all
        public static PagedList<email_template> email_template_plist(int pageindex, int pagesize)
        {
            var obj = new email_template_service();
            return obj.email_template_plist(pageindex, pagesize);
        }

        public static int email_template_update(email_template it)
        {
            var obj = new email_template_service();
            return obj.email_template_update(it);
        }
        //enable - disable  
        public static int updateStatus(int id, byte status)
        {
            var obj = new email_template_service();
            return obj.updateStatus(id, status);
        }

        //get items by id or code
        public static email_template getByID(int id)
        {
            var obj = new email_template_service();
            return obj.getByID(id);
        }

        //delete by id
        public static void deleteItem(int id)
        {
            var obj = new email_template_service();
            obj.deleteItem(id);
        }
    }
}